
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[EBAS_SP_HENT_LICENS_INFO]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)
drop procedure [dbo].[EBAS_SP_HENT_LICENS_INFO]
GO

SET QUOTED_IDENTIFIER OFF 
GO
SET ANSI_NULLS OFF 
GO

CREATE PROCEDURE [DBO].[EBAS_SP_HENT_LICENS_INFO] 
WITH ENCRYPTION	
AS
	DECLARE
		@antal int
		
	SET NOCOUNT ON	
	
	SET @antal = (SELECT COUNT(*) FROM EBAS_LICENS)
	
	SELECT LICENS_TIL, LICENS_NUMMER, LICENS_TYPE, SLUT_DATO, @antal AS ANTAL
	FROM EBAS_LICENS
	--WHERE SLUT_DATO > GetDate()
GO

SET QUOTED_IDENTIFIER OFF 
GO
SET ANSI_NULLS ON 
GO
